package com.qfjy.service.impl.example4;

import lombok.extern.slf4j.Slf4j;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Service;

@Service
@Slf4j
public class BlogServiceImpl {
    @RabbitListener(queues = {"javaQueue"})
    public void blogJava(String msg){

        log.info("Java发布的内容是---》{}",msg);
    }

    @RabbitListener(queues = {"pythonQueue"})
    public void blogPtyhon(String msg){

        log.info("Python发布的内容是---》{}",msg);
    }

    @RabbitListener(queues = {"allQueue"})
    public void blogAll(String msg){

        log.info("All发布的内容是---》{}",msg);
    }

}
